package com.example.springbootdesign.config;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;

@Component
public class ReadProperties {

    @Value("${my.name:默认值}")
    private String name;

    @Value("${my.age:18}")
    private Integer age;

    @Value("${my.topic:hahahah}")
    private String topic;

}
